-- GENERATED SPELL FOR [Un'Goro Gorilla] --


function spell0_6514(pUnit, Event) --@Growl,n/a--
pUnit:FullCastSpellOnTarget(14920,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6514', 0, 1)
end

function spell1_6514(pUnit, Event) --@Growl,n/a--
pUnit:FullCastSpellOnTarget(14921,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6514', 0, 1)
end

function spell2_6514(pUnit, Event) --@Smack,n/a--
pUnit:FullCastSpellOnTarget(49972,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6514', 615, 1)
end

function spell3_6514(pUnit, Event) --@Smack,n/a--
pUnit:FullCastSpellOnTarget(49974,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6514', 603, 1)
end

function Sorts_6514(pUnit, Event)
local choix_sorts_6514 = math.random(0, 3)
if choix_sorts_6514 == 0 then
pUnit:RegisterEvent('spell0_6514', 1, 1)
end
if choix_sorts_6514 == 1 then
pUnit:RegisterEvent('spell1_6514', 1, 1)
end
if choix_sorts_6514 == 2 then
pUnit:RegisterEvent('spell2_6514', 1, 1)
end
if choix_sorts_6514 == 3 then
pUnit:RegisterEvent('spell3_6514', 1, 1)
end
end

function mob6514_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_6514', math.random(1500, 3000), 1)
end

function mob6514_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6514_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6514_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(6514, 1, 'mob6514_Action')
RegisterUnitEvent(6514, 2, 'mob6514_Leave')
RegisterUnitEvent(6514, 3, 'mob6514_Kill')
RegisterUnitEvent(6514, 4, 'mob6514_Die')
